package com.lds.memory.kafka.partition.selector;

import java.util.concurrent.atomic.AtomicInteger;

public class DefaultPartitionSelector implements IPartitionSelector {
    private AtomicInteger counter = new AtomicInteger();
    @Override
    public int select(int partitionCount, String partitionKey) {
        counter.incrementAndGet();
        return counter.get() % partitionCount;
    }

}
